//
//  StellCaiculatorViewController.m
//  GLGW_Shoping
//
//  Created by yang on 2018/11/22.
//  Copyright © 2018年 yang. All rights reserved.
//

#import "StellCaiculatorViewController.h"
#import "StellCalculatorViewModel.h"
#import "CaiWeightAndLineViewController.h"

@interface StellCaiculatorViewController ()<StellCalculatorDelegate>
@property (nonatomic,strong) StellCalculatorViewModel * stellViewModel;
@end

@implementation StellCaiculatorViewController

- (void)viewDidLoad {
    [super viewDidLoad];
    self.title = @"计算器";
    self.stellViewModel =[[StellCalculatorViewModel alloc] initWithViewToViewCollectionView:self.collectionView theFlowLayout:self.flow theSuperView:self.view];
    self.stellViewModel.delegate = self;
    // Do any additional setup after loading the view.
}

#pragma mark -- StellCalculatorDelegate
-(void)stellDidSelectItemAtIndexPath:(NSIndexPath *)c_index{
    CaiWeightAndLineViewController * weightVC = [CaiWeightAndLineViewController new];
    weightVC.row_index = c_index.row;
    [self.navigationController pushViewController:weightVC animated:YES];
}

/*
#pragma mark - Navigation

// In a storyboard-based application, you will often want to do a little preparation before navigation
- (void)prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender {
    // Get the new view controller using [segue destinationViewController].
    // Pass the selected object to the new view controller.
}
*/

@end
